import Vue from 'vue'
import Router from 'vue-router'

// import Home from './page/home/Home.vue'
// import City from './page/city/City.vue'
// import Detail from './page/detail/Detail.vue'

Vue.use(Router)

export default new Router({
  routes: [
    { path: '/', component: () => import('./page/home/home.vue') },
    { path: '/city', component: () => import('./page/city/City.vue') },
    { path: '/detail', component: () => import('./page/detail/Detail.vue') }
  ],
  scrollBehavior(to, from, savedPosition) {
    return { x: 0, y: 0 }
  }
})
